package com.ril.financial.model;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import static javax.persistence.GenerationType.IDENTITY;

@Entity
public class Account implements java.io.Serializable {
    private String _bank;
    private String _number;
    private String _clabe;
    private Integer _id;

    public Account(String bank, String number, String clabe) {
        this.setBank(bank);
        this.setNumber(number);
        this.setClabe(clabe);
    }

    @Id
    @GeneratedValue(strategy = IDENTITY)
    public Integer getId() {
        return _id;
    }

    @Column(unique = false, nullable = false, length = 20)
    public String getBank() {
        return _bank;
    }

    public void setBank(String bank) {
        _bank = bank;
    }

    @Column(nullable = false, length = 50)
    public String getNumber() {
        return _number;
    }

    public void setNumber(String number) {
        _number = number;
    }

    @Column(unique = true, nullable = false, length = 30)
    public String getClabe() {
        return _clabe;
    }

    public void setClabe(String clabe) {
        _clabe = clabe;
    }

    public void setId(Integer id) {
        _id = id;
    }
}
